package org.example.springbootpra1.demos.data;

import com.alibaba.excel.enums.CellDataTypeEnum;
import com.alibaba.excel.metadata.data.RichTextStringData;
import com.alibaba.excel.metadata.data.WriteCellData;
import com.alibaba.excel.write.metadata.style.WriteFont;
import org.apache.poi.ss.usermodel.IndexedColors;
import org.example.springbootpra1.demos.bean.myAccount.RechargeRecord;
import org.example.springbootpra1.demos.bean.sheet.ChargetAccountRuleSheet;
import org.example.springbootpra1.demos.bean.sheet.CitySheet;
import org.example.springbootpra1.demos.bean.sheet.CompanySheet;
import org.example.springbootpra1.demos.bean.sheet.UserSheet;

import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.List;

public class MyAcountMock {

    public static List<RechargeRecord> accountList() {
        // 定义时间字符串
        String dateString = "2023-10-05T14:30:00";

        // 创建 DateTimeFormatter
        DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd'T'HH:mm:ss");

        // 解析时间字符串
        LocalDateTime dateTime = LocalDateTime.parse(dateString, formatter);
        List<RechargeRecord> list = new ArrayList<>(10);
        list.add(RechargeRecord.builder().id(0L).type(2).amount(BigDecimal.valueOf(-100)).date(dateTime).build());

        list.add(RechargeRecord.builder().id(1L).type(1).amount(BigDecimal.valueOf(10)).date(dateTime).build());

        list.add(RechargeRecord.builder().id(2L).type(1).amount(BigDecimal.valueOf(20)).date(dateTime).build());
        list.add(RechargeRecord.builder().id(3L).type(2).amount(BigDecimal.valueOf(-20)).date(dateTime).build());
        list.add(RechargeRecord.builder().id(4L).type(1).amount(BigDecimal.valueOf(20)).date(dateTime).build());
        list.add(RechargeRecord.builder().id(5L).type(2).amount(BigDecimal.valueOf(-20)).date(dateTime).build());
        list.add(RechargeRecord.builder().id(6L).type(1).amount(BigDecimal.valueOf(20)).date(dateTime).build());
        list.add(RechargeRecord.builder().id(7L).type(1).amount(BigDecimal.valueOf(20)).date(dateTime).build());
        list.add(RechargeRecord.builder().id(8L).type(1).amount(BigDecimal.valueOf(20)).date(dateTime).build());
        list.add(RechargeRecord.builder().id(9L).type(1).amount(BigDecimal.valueOf(20)).date(dateTime).build());
        list.add(RechargeRecord.builder().id(10L).type(1).amount(BigDecimal.valueOf(20)).date(dateTime).build());
        list.add(RechargeRecord.builder().id(11L).type(1).amount(BigDecimal.valueOf(20)).date(dateTime).build());
        list.add(RechargeRecord.builder().id(12L).type(1).amount(BigDecimal.valueOf(20)).date(dateTime).build());
        list.add(RechargeRecord.builder().id(13L).type(1).amount(BigDecimal.valueOf(20)).date(dateTime).build());
        list.add(RechargeRecord.builder().id(14L).type(1).amount(BigDecimal.valueOf(20)).date(dateTime).build());

        return list;
    }


}
